<?php
declare(strict_types=1);

namespace ServerApp\lib\server\model\redis;

use WebApp\lib\config\Config;
use WebApp\lib\db\HashTable;

/**
 * Class Session
 */
class Session extends HashTable
{
    const KEY= 'session_id';
    const VAL= 'data';

    /**
     * users constructor.
     */
    private function __construct(){}

    private static $instance = null;

    /**
     * @return null|Session
     */
    public static function getInstance(){
        if (self::$instance == null){
            self::$instance = new self();
            self::$instance->init(Config::getConf('project'), __CLASS__);
        }
        return self::$instance;
    }
}